#include "wifi.h"
#include <Arduino.h>

void WifiManager::connect(const char* ssid, const char* password) {
    WiFi.begin(ssid, password);
    Serial.print("连接 WiFi");
    while (WiFi.status() != WL_CONNECTED) {
        delay(500);
        Serial.print(".");
    }
    Serial.println("\n✅ WiFi 已连接！");
    Serial.println(WiFi.localIP());
}